// Room builders
//--------------------------------
#ifndef ROOMBUILDERS_H
#define ROOMBUILDERS_H
#include "common.h"
#include "mapbuilder.h"

class RBBoxRoom : public RoomBuilder {
public:

    RBBoxRoom() : left( 0 ), right( 0 ), top( 0 ), bottom( 0 ) { }
    virtual ~RBBoxRoom() { }

    virtual void GetRoomSize( int& width, int& height ) const;

protected:

    virtual void BuildInternal( int width, int height );
    int left, right, top, bottom;

};

class RBPassage : public RoomBuilder {
public:

    RBPassage() { }
    virtual ~RBPassage() { }

    virtual void GetRoomSize( int& width, int& height ) const;

protected:

    virtual void BuildInternal( int width, int height );

};

class RBPillarRoom : public RBBoxRoom {
public:

    RBPillarRoom() { }
    virtual ~RBPillarRoom() { }

    virtual void GetRoomSize( int& width, int& height ) const;

protected:

    virtual void BuildInternal( int width, int height );

};

class RBSubRoom : public RBBoxRoom {
public:

    RBSubRoom() { }
    virtual ~RBSubRoom() { }

    virtual void GetRoomSize( int& width, int& height ) const;

protected:

    virtual void BuildInternal( int width, int height );

};

class RBAutomataCave : public RoomBuilder {
public:

    RBAutomataCave() { }
    virtual ~RBAutomataCave() { }

    virtual void GetRoomSize( int& width, int& height ) const;

protected:

    virtual void BuildInternal( int width, int height );

};

class RBOrganicCave : public RoomBuilder {
public:

    RBOrganicCave() { }
    virtual ~RBOrganicCave() { }

    virtual void GetRoomSize( int& width, int& height ) const;

protected:

    virtual void BuildOrganic( int width, int height, int nMin, int nMax, int conChance );
    virtual void BuildInternal( int width, int height );

};

class RBLabyrinth : public RBOrganicCave {
public:

    RBLabyrinth() { }
    virtual ~RBLabyrinth() { }

    virtual void GetRoomSize( int& width, int& height ) const;

protected:

    virtual void BuildInternal( int width, int height );

};

class RBLabyrinthCave : public RBOrganicCave {
public:

    RBLabyrinthCave() { }
    virtual ~RBLabyrinthCave() { }

    virtual void GetRoomSize( int& width, int& height ) const;

protected:

    virtual void BuildInternal( int width, int height );

};

#endif